﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace TracNghiemTinHocDaiCuong
{
    public partial class THDC : System.Web.UI.MasterPage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Session["idNguoiDung"] != null)
            {
                lkbtnDangNhap.Text = "Đăng xuất";
            }
            else
            {
                if (lkbtnDangNhap != null)
                    lkbtnDangNhap.Text = "Đăng nhập";
            }
        }

        protected void lkbtnDangNhap_Click(object sender, CommandEventArgs e)
        {
            if (Session["idNguoiDung"] != null)
            {
                Session["idNguoiDung"] = null;
                Response.Redirect("GioiThieu.aspx");
            }
            else
            {
                Response.Redirect("DangNhap.aspx");
            }
        }
    }
}